class Screen(object):
    @property
    def width(self):
        return self._width

    @property
    def heigth(self):
        return self._heigth

    @property
    def resolution(self):
        return "%s x %s= %s" % (self._width, self._heigth, self._heigth * self._width)

    @width.setter
    def width(self, value):
        self._width = value

    @heigth.setter
    def heigth(self, value):
        self._heigth = value


s = Screen()
s.width = 1024
s.heigth = 768
print(s.resolution)
#  assert s.resolution == 786432, '1024 * 768 = %d ?' % s.resolution
